﻿
     var city_dw=1; var cityname_wang; var areadis="-1";var dayflag="0";var sort="0";
     
    if(typeof(getCookie("ztyingonde"))!="undefined" && getCookie("ztyingonde")!=null&& getCookie("ztyingonde")!=0)
    {
        city_dw=getCookie("ztyingonde");
    }
 
    function AreaBoxShow(cityid,disid,ccount)
    {
        LoadCityDis(disid);
        $("#pcount").text(ccount);
        loadCimemaShowL(city_dw,areadis,dayflag,sort);
    }
    
    function LoadCityDis(disid)
    {
        var disname;
        areadis=disid;
        $("#areafilmlist a").each(function (){
            var d=$(this).attr("id");
            d=d.substring(3,d.length);
            if(d==disid)
            {
                disname=$(this).text();
            }
        });
        $("#filmareadis").text(disname);
    }
    
    function loadCityName(cityid) {
        //alert("cityId1=" + cityid);
        $("#searchlistcity a").each(function(){
            var spanid=$(this).attr("id");
            if(spanid==cityid)
            {
                cityname_wang=$(this).text();
                $("#cityname_wangli").text(cityname_wang);
            }
        });
        //alert("cityId2=" + cityid);
    }
    
    //此处需要改造
    function bindrepList(cityid) {
//        alert("cityId3=" + cityid);

        $("#CityDis").html('<img src="/imagesnew/loading.gif" style="width: 16px; height: 16px" />数据正在加载......').load("/AjaxCMS/ajax_Film_area" + cityid + ".html");
 
//        $.ajax({
//            type: "get",
//            dataType: "html",
//            url: "/AjaxCMS/ajax_Film_areacount.html",
//            async: false,
//            data: "cityid="+cityid,
//            beforeSend :function(){$("#ccount1").html('<img src="/Buyticket/images/loading1.gif" width="16" height="16" />数据正在加载......');},
//            success: function(msg){
//                $("#ccount1").html(msg); 
//            }
//        });
//        alert("cityId4=" + cityid);
    }
        
    //此函数需要改造
    function loadCimemaShowL(cityid,distid,dayflag,sort)
    {
//        $.ajax({
//            type: "get",
//            dataType: "html",
//            url: "/AjaxCMS/ajax_NewFilmcount.html",
//            async: false,
//            data: "cityid="+cityid+"&area="+areadis+"&dayflag="+dayflag,
//            beforeSend :function(){$("#FilmCountList").html('<img src="/Buyticket/images/loading1.gif" width="16" height="16" />数据正在加载......');},
//            success: function(msg){
//                $("#FilmCountList").html(msg); 
//            }
//        });

        //alert("cityId5=" + cityid + " distid=" + distid + " dayflag=" + dayflag + " sort=" + sort);

        $("#FilmList").html('<img src="/imagesnew/loading.gif" style="width: 16px; height: 16px" />数据正在加载......').load("/AjaxCMS/ajax_NewFilmList.aspx?cityId=" + cityid + "&distid=" + distid + "&dayflag=" + dayflag + "&sort=" + sort);

        alert("fileList Src=" + "/AjaxCMS/ajax_NewFilmList.aspx?cityId=" + cityid + "&distid=" + distid + "&dayflag=" + dayflag + "&sort=" + sort);

//        $.ajax({
//            type: "get",
//            dataType: "html",
//            url: "/AjaxCMS/ajax_NewFilmList.html", //?cityid="+cityidliu, 
//            async: false,
//            data: "cityid="+cityid+"&area="+areadis+"&dayflag="+dayflag+"&sort="+sort,
//            beforeSend :function(){$("#FilmList").html('<img src="/Buyticket/images/loading1.gif" width="16" height="16" />数据正在加载......');},
//            success: function(msg){
//                $("#FilmList").html(msg); 
//            }
//        });

        //alert("cityId6=" + cityid);
    }